package com.baiyi.cloud.platform;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cloud.client.discovery.EnableDiscoveryClient;
import org.springframework.context.annotation.Configuration;

import com.ctrip.framework.apollo.spring.annotation.EnableApolloConfig;
import com.baiyi.cloud.platform.autoconfigure.port.PortApplicationEnvironmentPreparedEventListener;

/**
 * 
 * @ClassName: FileCenterApp
 * @Description: 文件中心
 * @author huwenfeng
 * @date 2019年1月10日
 */
@Configuration
@EnableApolloConfig
@EnableDiscoveryClient
@SpringBootApplication
public class FileCenterApp {

	public static void main(String[] args) {
		// 固定端口
		// SpringApplication.run(FileCenterApp.class, args);

		// 随机端口启动
		SpringApplication app = new SpringApplication(FileCenterApp.class);
		app.addListeners(new PortApplicationEnvironmentPreparedEventListener());
		app.run(args);

	}

}